
		**********************************************************
		** File: cleaning_3P.do									**
		** Paper: Human Trafficking Indicators: A New Dataset	**
		** Author: Richard Frank								**
		** Date: July 11, 2021									**
		** Task: cleaning 3P INDEX								**
		**********************************************************
							 
							
		clear
		version 16
		set seed 1234
				 
		** Data source: http://economics-human-trafficking.org/data-and-reports.html		 
				 
		import excel "3P_Index_2000-2015.xlsx", ///
			sheet("2000-2015") cellrange(A3:G2919) firstrow case(lower) clear
		rename country Country
		run "cow.do"
		browse if ccode== 710
		drop if Country=="Hong Kong"
		drop if Country=="Macau"	
		browse if ccode==0
		drop if ccode==0
		label var prosecution "Prosecution index (3P)"
		label var protection "Protection index (3P)"
		label var prevention "Prevention index (3P)"
		label var overall3p "3P Index (3P)"	
		sort ccode year
		duplicates report ccode year
		browse if ccode==ccode[_n-1] & year==year[_n-1]

		save "data3P_2015.dta", replace			
							
		 
						
			
